Storage policy: remove DROP NATIVE, add reserved TO REMOTE stage#458
Merged
Conversation
|
🚀 Build success! Latest successful preview: https://preview-458--questdb-documentation.netlify.app/docs/ Commit SHA: 79dba3f
|
javier
requested changes
May 29, 2026
javier
approved these changes
May 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Updates the storage policy documentation to match the new lifecycle model.
DROP NATIVEis removed entirely. Converting a partition withTO PARQUETnow removes the native files in place and serves reads directly from the Parquet file, so a separate native-drop stage is no longer needed. Thedrop_nativecolumn is dropped from thestorage_policiessystem view.A reserved
TO REMOTEstage is added, mirroring the existing reservedDROP REMOTEclause. This makes the lifecycle coherent for the future object storage integration: convert locally, upload to remote, drop the local copy, then drop the remote copy. Both remote stages are rejected at SQL parse time and surface as always-blank columns in the system view.The stages now form a partial order rather than a single chain. A drop stage may not fire before the write it depends on:
TO PARQUETandTO REMOTEare independent. IfTO REMOTEfires first, both native and Parquet copies are written locally and reads are served from native untilTO PARQUETremoves the native files.TO PARQUETandDROP LOCALare active today;TO REMOTEandDROP REMOTEare reserved for a future release.Changes by area:
concepts/storage-policy.md): lifecycle diagram, stage table, TTL evaluation, ordering constraint,storage_policiesexample, and guidelines.alter-table-set-storage-policy.md,alter-mat-view-set-storage-policy.md,create-table.md,create-mat-view.md,show.md): syntax blocks, stage tables, constraints, examples, andSHOW CREATE TABLEoutput.query/functions/meta.md):storage_policiescolumn reference and example tables (removeddrop_native, added reservedto_remote).getting-started/enterprise-quick-start.md,operations/backup.md,high-availability/overview.md): migration guidance, backup interaction, and replicated-policy description.Dependencies
This documents an engine behavior change and should merge alongside the corresponding QuestDB Enterprise PR. The reserved
TO REMOTEparse error is documented as'TO REMOTE' is not supported yet, mirroringDROP REMOTE; confirm the exact string and theto_remoteview column name against the engine implementation before merging.